<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>11.演示跨域</title>
    <script>
         function hello(data) {
             console.log(data);
        }
    </script>
    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/2.2.4/jquery.js"></script>
    
    <script src="https://opendata.baidu.com/api.php?resource_id=51274&ks_from=aladdin&new_need_di=1&from_mid=1&sort_type=1&query=%E5%A5%BD%E7%9C%8B%E7%9A%84%E7%94%B5%E5%BD%B1&tn=wisexmlnew&dsp=iphone&format=json&ie=utf-8&oe=utf-8&q_ext=%7B%22query_key%22%3A3%2C%22is_person_related%22%3A0%2C%22video_type_list%22%3A%5B%5D%7D&sort_key=3&stat0=%E7%94%B5%E5%BD%B1&stat1=%E5%85%A8%E9%83%A8&stat2=%E5%85%A8%E9%83%A8&stat3=%E5%85%A8%E9%83%A8&rn=10&pn=8&trigger_srcid=51251&sid=39712_39840_39904_39819_39909_39934_39933_39944_39941_39939_39931_39781_39974_39662_40011&cb=hello"></script>
</head>
<body>
    <button id="btnNode">获取数据</button>

    <script>

       
        // btnNode.onclick = function() {
        
        //     // https://opendata.baidu.com/api.php?resource_id=51274&ks_from=aladdin&new_need_di=1&from_mid=1&sort_type=1&query=%E5%A5%BD%E7%9C%8B%E7%9A%84%E7%94%B5%E5%BD%B1&tn=wisexmlnew&dsp=iphone&format=json&ie=utf-8&oe=utf-8&q_ext=%7B%22query_key%22%3A3%2C%22is_person_related%22%3A0%2C%22video_type_list%22%3A%5B%5D%7D&sort_key=3&stat0=%E7%94%B5%E5%BD%B1&stat1=%E5%85%A8%E9%83%A8&stat2=%E5%85%A8%E9%83%A8&stat3=%E5%85%A8%E9%83%A8&rn=10&pn=8&trigger_srcid=51251&sid=39712_39840_39904_39819_39909_39934_39933_39944_39941_39939_39931_39781_39974_39662_40011&qq-pf-to=pcqq.group
        //      $.ajax({
        //         url:"https://opendata.baidu.com/api.php?resource_id=51274&ks_from=aladdin&new_need_di=1&from_mid=1&sort_type=1&query=%E5%A5%BD%E7%9C%8B%E7%9A%84%E7%94%B5%E5%BD%B1&tn=wisexmlnew&dsp=iphone&format=json&ie=utf-8&oe=utf-8&q_ext=%7B%22query_key%22%3A3%2C%22is_person_related%22%3A0%2C%22video_type_list%22%3A%5B%5D%7D&sort_key=3&stat0=%E7%94%B5%E5%BD%B1&stat1=%E5%85%A8%E9%83%A8&stat2=%E5%85%A8%E9%83%A8&stat3=%E5%85%A8%E9%83%A8&rn=10&pn=8&trigger_srcid=51251&sid=39712_39840_39904_39819_39909_39934_39933_39944_39941_39939_39931_39781_39974_39662_40011&qq-pf-to=pcqq.group",
        //         success:function(data) {
        //             console.log(data);
        //         }
        //     })
        // }

    </script>
    
</body>
</html>